﻿using System.Reflection;

namespace KingerRobot.MexicoSailunMDC.SpiService;

internal interface IWarehousOut
{
    void CreateTaskByLocOrders(OrderSummaryGroupyMaster master, List<CrnForkInfo> crnForks);
    /// <summary>
    /// 按条码出库创建任务
    /// </summary>
    /// <param name="master"></param>
    /// <param name="crnForks"></param>
    void CreateTaskByProductCodeOrders(OrderSummaryGroupyMaster master, List<CrnForkInfo> crnForks);
    /// <summary>
    /// 安装库位出库创建任务
    /// </summary>
    /// <param name="master">任务货叉</param>
    /// <param name="crnForks"></param>
    void CreateTaskByLocOrder(OrderSummaryGroupyMaster master, List<CrnForkInfo> crnForks);
    /// <summary>
    /// 根据路线分数创建任务
    /// </summary>
    /// <param name="asrsOutInfoBeans">总的出库路线</param>
    /// <param name="asrsNetOutputs">符合当前订单的出库路线</param>
    /// <param name="platformLocs">出库站台</param>
    /// <param name="wcsAsrsLocHalts">停机货位</param>
    /// <param name="master">订单</param>
    /// <param name="locations">可用库位库存</param>
    /// <returns></returns>
    ///

    List<WcsAsrsNetOutputGroup> CreateTaskRoutine(List<WcsAsrsNetOutputGroup> asrsOutInfoBeans, List<NetOutEntity> asrsNetOutputs, List<CrnOutLoc> platformLocs, List<POWcsAsrsLocHalt> wcsAsrsLocHalts,
        OrderSummaryGroupyMaster master, List<CanStock> locations);
    /// <summary>
    /// 
    /// </summary>
    /// <param name="asrsOutInfoBeans">所有出库路线</param>
    /// <param name="asrsNetOutputs">过滤后出库路线</param>
    /// <param name="platformLocs">出库放胎位</param>
    /// <param name="wcsAsrsLocHalts">停机货位</param>
    /// <param name="master">请料单</param>
    /// <param name="locations">可用货位</param>
    /// <returns></returns>
    List<WcsAsrsNetOutputGroup> CreateTaskRoutineV2(List<WcsAsrsNetOutputGroup> asrsOutInfoBeans, List<NetOutEntity> asrsNetOutputs, List<CrnOutLoc> platformLocs, List<POWcsAsrsLocHalt> wcsAsrsLocHalts,
        OrderSummaryGroupyMaster master, List<CanStock> locations);
    /// <summary>
    /// 根据路线库存时间创建任务
    /// </summary>
    /// <param name="asrsOutInfoBeans">总的出库路线</param>
    /// <param name="asrsNetOutputs">符合当前订单的出库路线</param>
    /// <param name="platformLocs">出库站台</param>
    /// <param name="wcsAsrsLocHalts"></param>
    /// <param name="master">订单</param>
    /// <param name="limitTime">最早库存日期</param>
    /// <returns></returns>
    List<WcsAsrsNetOutputGroup> CreateTaskLimit(List<WcsAsrsNetOutputGroup> asrsOutInfoBeans, List<NetOutEntity> asrsNetOutputs, List<CrnOutLoc> platformLocs,
       List<POWcsAsrsLocHalt> wcsAsrsLocHalts, OrderSummaryGroupyMaster master, DateTime limitTime);
}
